import java.io.BufferedReader;
import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.IOException;
import java.io.InputStreamReader;
import java.net.Socket;

import javax.swing.JFrame;
import javax.swing.JOptionPane;


public class ReceiveFile {
	Socket socket = null;
	
	
	public ReceiveFile(Socket s){
		socket = s;
	}
	
	public void makeSocket(){
		JFrame frame = new JFrame();
		DataInputStream is = null;
		DataOutputStream os = null;
		BufferedReader buffer = null;
		try {
			buffer = new BufferedReader(new InputStreamReader(socket.getInputStream()));
			String filename = buffer.readLine();
			JOptionPane.showMessageDialog(frame, filename);
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		
	}
}
